package com.sojoys.artifact.factory.template;

import java.io.Writer;
import java.util.Map;

import org.beetl.core.Template;

/**
 * @author : DengYing
 * @CreateDate : 2017年7月6日 上午11:12:22
 * @Description ：Please describe this document
 */
@SuppressWarnings("rawtypes")
public class BeetlTemplate extends ITemplate<Template> {

	
	public BeetlTemplate(Template template) {
		super();
		t = template;
	}

	
	@Override
	public String render(Map map) {
		t.binding(map);
		return t.render();
	}

	@Override
	public void renderTo(Map map,Writer writer) {
		t.binding(map);
		t.renderTo(writer);
	}

//	@Override
//	public void renderTo(Map map,OutputStream out) {
//		t.binding(map);
//		t.renderTo(out);
//	}

}
